Electronic devices, such as mobile phones, personal digital assistants, include loudspeakers for implementing the multi-media playing function. The electronic devices commonly define receiving chambers for receiving the loudspeakers, and resonant cavities for sounds emitted by the loudspeakers to resonate. However, the volume of the loudspeaker may not be high enough or satisfy the requirements of the user.